package com.browan.freepp.android.util;

import java.io.Closeable;
import java.io.IOException;

import android.database.Cursor;
import android.util.Log;

/**
 * @author Administrator David some use methods
 */
public class OsyncUtil {

	private final static String TAG = "OsyncUtil";

	public static void close(Closeable stream) {

		if (null != stream) {
			try {
				stream.close();
			} catch (IOException e) {
				Log.e(TAG, e.toString());
			}
			stream = null;
		}
	}
	
	public static void close(Cursor cursor)
	{
		if(null != cursor)
			cursor.close();
		cursor = null;
	}
}